import  request from  "../../until/axios"
export const swiperlist = (params) =>
  request({
    method: "get",
    url: "/prod-api/api/takeout/rotation/list",
    params,
    headers:{
      "Authorization":window.localStorage.getItem("token")
  }
  });
export const theme = (params) =>
  request({
    method: "get",
    url: "/prod-api/api/takeout/theme/list",
    params,
    headers:{
      "Authorization":window.localStorage.getItem("token")
  }
  });
export const near = (params) =>
  request({
    method: "get",
    url: "/prod-api/api/takeout/seller/near",
    params,
    headers:{
      "Authorization":window.localStorage.getItem("token")
  }
  });
export const searchlist = (params) =>
  request({
    method: "get",
    url: "/prod-api/api/takeout/search",
    params,
    headers:{
      "Authorization":window.localStorage.getItem("token")
  }
  });
export const restaurantlist = (params) =>
  request({
    method: "get",
    url: "/prod-api/api/takeout/seller/list",
    params,
    headers:{
      "Authorization":window.localStorage.getItem("token")
  }
  });
export const restaurantDetail = (id) =>
  request({
    method: "get",
    url: "/prod-api/api/takeout/seller/"+id,
    headers:{
      "Authorization":window.localStorage.getItem("token")
  }
  });
export const menulist = (params) =>
  request({
    method: "get",
    url: "/prod-api/api/takeout/product/list",
    params,
    headers:{
      "Authorization":window.localStorage.getItem("token")
  }
  });
export const commentlist = (params) =>
  request({
    method: "get",
    url: "/prod-api/api/takeout/comment/list",
    params,
    headers:{
      "Authorization":window.localStorage.getItem("token")
  }
  });
export const createlist = (data) =>
  request({
    method: "post",
    url: "/prod-api/api/takeout/order/create",
    data,
    headers:{
      "Authorization":window.localStorage.getItem("token")
  }
  });
